home *** CD-ROM | disk | FTP | other *** search
- property pScrollDelay, pButtonClicked, pDirection
-
- on beginSprite me
- set pScrollDelay to 10
- set currentMember to the member of sprite the spriteNum of me
- if the name of member currentMember contains "up" then
- set pDirection to #up
- else
- set pDirection to #down
- end if
- end
-
- on mouseDown me
- set pButtonClicked to 1
- sendAllSprites(#scrollText, pDirection)
- startTimer()
- end
-
- on mouseLeave me
- set pButtonClicked to 0
- end
-
- on mouseUp me
- set pButtonClicked to 0
- end
-
- on mouseWithin me
- if pButtonClicked = 1 then
- if the mouseDown and (the timer > pScrollDelay) then
- sendAllSprites(#scrollText, pDirection)
- end if
- end if
- end
-